#define _CRT_SECURE_NO_WARNINGS
#include <iostream>
#include<string>
using namespace std;
int main()
{
	string val;
	cin >> val;
	int begin = 0;
	double weight = 1;
	int length = val.size();
	if (int(val[length - 1] - '0') % 2 == 0)
		weight *= 2;
	if (val[0] == '-')
	{
		weight *= 1.5;
		begin = 1;
		length--;
	}

	int times = 0;
	for (int i = begin; i < length; i++)
	{
		if (val[i] == '2')
			times++;
	}
	system("PAUSE");
	double fool = weight * times / length * 100;
	printf("%.2f%%",fool);
	return 0;
}